Skip to content

Search handler and client with HTTP POST-based request serialization. #8892

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Aug 14, 2025

Conversation

isoos
Copy link
Collaborator

@isoos isoos commented Aug 12, 2025

@isoos isoos requested a review from sigurdm August 12, 2025 15:48
Future<shelf.Response> _debugHandler(shelf.Request request) async {
final info = await searchIndex.indexInfo();
return debugResponse(info.toJson());
}

/// Handles /search requests.
/// Handles GET /search requests.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to contradict the code below that branches on the method....

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated comment, it should handle both.

@@ -53,7 +53,6 @@ enum SearchOrder {
/// WARNING: The value shouldn't be used anymore.
///
/// TODO: remove in a future release.
@Deprecated('Popularity is no longer used.')
popularity,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this intentional?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Intentional, but more of a convenience: if we keep it, the generated code uses it and analyzer complains about using a deprecated field. I did not want to remove it yet, but maybe we should?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed the field. I think we did have enough time since we have changed from popularity to downloads. Old bookmarks may break, but that is going to happen no matter when we remove it.

@isoos isoos merged commit 59af9a0 into dart-lang:master Aug 14, 2025
31 checks passed
@isoos isoos deleted the search-post branch August 14, 2025 09:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants